<template>
    <div class="jd-navbabbar">
        <van-nav-bar
        :title='title'
        left-arrow
        fixed
        @click-left='back'
        >
            <template #right>
            <slot></slot>
            </template>
        </van-nav-bar>

    </div>
</template>
<script>
import {NavBar} from 'vant'
export default {
    components:{
        [NavBar.name]:NavBar
    },
    props:{
    title: { type: String, required: false, default: '标题' }

    },
    methods:{
        back(){
            // this.$emit("back")
            this.$router.back()

        },

    }
    
}
</script>
<style lang="scss" scoped>

</style>